﻿using System.Collections.Generic;
using YNTK.Common.Util;
using YNTK.Dependency;

namespace YNTK.System.Entitys.Dto.Mechanism
{
    /// <summary>
    /// 机构树结构数据传输模型
    /// </summary>
    [SuppressSniffer]
    public class MechanismTreeListDto
    {
        /// <summary>
        /// 机构id
        /// </summary>
        /// <returns></returns>
        public string id { get; set; }

        /// <summary>
        /// 父级机构id
        /// </summary>
        /// <returns></returns>
        public string parentId { get; set; }

        /// <summary>
        /// 是否有子级
        /// </summary>
        public bool hasChildren { get; set; } = false;

       /// <summary>
       /// 子级数据
       /// </summary>
        public List<MechanismTreeListDto> children { get; set; }

        /// <summary>
        /// 子节点数量
        /// </summary>
        public int num { get; set; }

        /// <summary>
        /// 是否为子节点
        /// </summary>
        public bool isLeaf { get; set; } = false;

        /// <summary>
        /// 机构类型(0.分支机构 1.部门 2.岗位 3.职位 4.职务)
        /// </summary>
        public int type { get; set; }

        /// <summary>
        /// 机构类型文本
        /// </summary>
        public string typeText { get; set; }

        /// <summary>
        /// 完全父级id,拼接上所有父级
        /// </summary>
        public string allParentId { get; set; }

        /// <summary>
        /// 机构编码
        /// </summary>
        public string code { get; set; }

        /// <summary>
        /// 机构名称
        /// </summary>
        public string name { get; set; }

        /// <summary>
        /// 机构主管id
        /// </summary>
        public string managerId { get; set; }

        /// <summary>
        /// 机构主管姓名
        /// </summary>
        public string managerName{ get; set; }

        /// <summary>
        /// 机构主管头像服务器存储路径
        /// </summary>
        public string headIcon { get; set; }

        /// <summary>
        /// 机构主管头像base64
        /// </summary>
        public string headIconBase64 { get; set; }

        /// <summary>
        /// 备注
        /// </summary>
        public string description { get; set; }

        /// <summary>
        /// 职责
        /// </summary>
        public string responsibility { get; set; }

        /// <summary>
        /// 职责,岗位说明书文件存储路径
        /// </summary>
        public string responsibilityFilePath { get; set; }

        /// <summary>
        /// 职责,岗位说明书文件名称
        /// </summary>
        public string responsibilityFileName { get; set; }

        /// <summary>
        /// 目标
        /// </summary>
        public string target { get; set; }

        /// <summary>
        /// 目标,完成情况统计文件存储路径
        /// </summary>
        public string targetFilePath { get; set; }

        /// <summary>
        /// 目标,完成情况统计文件名称
        /// </summary>
        public string targetFileName { get; set; }

        /// <summary>
        /// 定置定位文件服务器存储路径
        /// </summary>
        public string orientationFilePath { get; set; }

        /// <summary>
        /// 定置定位文件名称
        /// </summary>
        public string orientationFileName { get; set; }

        /// <summary>
        /// 排序码
        /// </summary>
        public long? sortCode { get; set; }

        /// <summary>
        /// 启用/禁用,1.启用
        /// </summary>
        public int? enabledMark { get; set; }
    }

    /// <summary>
    /// 机构树结构数据传输模型
    /// </summary>
    [SuppressSniffer]
    public class MechanismTreeDto: TreeModel
    {
        /// <summary>
        /// 机构类型(0.分支机构 1.部门 2.岗位 3.职位 4.职务)
        /// </summary>
        public int type { get; set; }

        /// <summary>
        /// 机构类型文本
        /// </summary>
        public string typeText { get; set; }

        /// <summary>
        /// 完全父级id,拼接上所有父级
        /// </summary>
        public string allParentId { get; set; }

        /// <summary>
        /// 机构编码
        /// </summary>
        public string code { get; set; }

        /// <summary>
        /// 机构名称
        /// </summary>
        public string name { get; set; }

        /// <summary>
        /// 机构主管id
        /// </summary>
        public string managerId { get; set; }

        /// <summary>
        /// 机构主管姓名
        /// </summary>
        public string managerName { get; set; }

        /// <summary>
        /// 机构主管头像服务器存储路径
        /// </summary>
        public string headIcon { get; set; }

        /// <summary>
        /// 机构主管头像base64
        /// </summary>
        public string headIconBase64 { get; set; }

        /// <summary>
        /// 备注
        /// </summary>
        public string description { get; set; }

        /// <summary>
        /// 职责
        /// </summary>
        public string responsibility { get; set; }

        /// <summary>
        /// 职责,岗位说明书文件存储路径
        /// </summary>
        public string responsibilityFilePath { get; set; }

        /// <summary>
        /// 职责,岗位说明书文件名称
        /// </summary>
        public string responsibilityFileName { get; set; }

        /// <summary>
        /// 目标
        /// </summary>
        public string target { get; set; }

        /// <summary>
        /// 目标,完成情况统计文件存储路径
        /// </summary>
        public string targetFilePath { get; set; }

        /// <summary>
        /// 目标,完成情况统计文件名称
        /// </summary>
        public string targetFileName { get; set; }

        /// <summary>
        /// 定置定位文件服务器存储路径
        /// </summary>
        public string orientationFilePath { get; set; }

        /// <summary>
        /// 定置定位文件名称
        /// </summary>
        public string orientationFileName { get; set; }

        /// <summary>
        /// 排序码
        /// </summary>
        public long? sortCode { get; set; }

        /// <summary>
        /// 启用/禁用,1.启用
        /// </summary>
        public int? enabledMark { get; set; }
    }

    /// <summary>
    /// 机构树
    /// </summary>
    [SuppressSniffer]
    public class MechanismTree: TreeModel
    {
        /// <summary>
        /// 机构类型(0.分支机构 1.部门 2.岗位 3.职位 4.职务)
        /// </summary>
        public int type { get; set; }

        /// <summary>
        /// 机构编码
        /// </summary>
        public string code { get; set; }

        /// <summary>
        /// 机构名称
        /// </summary>
        public string name { get; set; }

        /// <summary>
        /// 排序码
        /// </summary>
        public long? sortCode { get; set; }
    }
}
